package com.nameless.service;

import com.baomidou.mybatisplus.extension.service.IService;
import com.nameless.entity.Menu;
import com.nameless.vo.Result;
import com.nameless.vo.TreeSelect;

import java.util.List;

/**
 * @author keluoyisi
 */
public interface MenuService extends IService<Menu> {

    List<Menu> selectPermission(Integer userId);

    /**
     * 获取左菜单
     *
     * @return {@link List}<{@link Menu}>
     */
    List<Menu> leftMenu();

    Result qr(Integer roleId, Integer[] menuids);

    Result findMenuByRoleId(Integer roleId);

    List<Menu> findAllParent(Integer id);
    /**
     * 获取菜单并分级
     *
     * @return {@link List}<{@link Menu}>
     */
    List<TreeSelect> listWithClass();
}